#include<iostream>
using namespace std;
int main(){
    double A[3];
    for (int i=0;i<3;i++){
        double a,b,c;
        cin>>a>>b>>c;
        if (a>b&&a>c)
        {
            cout<<"W ";
            A[i]=a;
        }else if(b>c&&b>a){
            cout<<"T ";
            A[i]=b;
        }else{
            cout<<"L ";
            A[i]=c;
        }
        
    } 
    double sum;
    sum=(A[0]*A[1]*A[2]*0.65-1)*2;
    cout<<sum;
}
